/*
 *      ID : pallab81
 *      PROG : 222
 *      LANG : C++
 *
 *      2012-06-28 07:52:10
 *      "I have not failed, I have just found 10000 ways that won't work.
 */

#include <iostream>
#include <algorithm>
#include <vector>
#include <sstream>
#include <fstream>
#include <string>
#include <list>
#include <map>
#include <set>
#include <queue>
#include <deque>
#include <stack>
#include <functional>
#include <bitset>
#include <iomanip>

#include <ctime>
#include <cassert>
#include <cstdio>
#include <cmath>
#include <cstring>
#include <climits>
#include <cstdlib>

using namespace std;


#define foR(i1,st,ed) for(int i1 = st , j1 = ed ; i1 < j1 ; ++i1 )
#define fo(i1,ed) foR( i1 , 0 , ed )
#define foE(i1,st,ed) foR( i1, st, ed+1 )
#define foit(i, x) for (typeof((x).begin()) i = (x).begin(); i != (x).end(); i++)
#define bip system("pause")
#define Int long long
#define pb push_back
#define SZ(X) (int)(X).size()
#define LN(X) (int)(X).length()
#define mk make_pair
#define SET( ARRAY , VALUE ) memset( ARRAY , VALUE , sizeof(ARRAY) )
#define line putchar_unlocked('\n')

template<class T1>
inline void debug(T1 _x) {
    cout<<_x<<'\n';
}
template<class T1, class T2>
inline void debug(T1 _x,T2 _y) {
    cout<<_x<<' '<<_y<<'\n';
}
template<class T1, class T2, class T3>
inline void debug(T1 _x,T2 _y,T3 _z) {
    cout<<_x<<' '<<_y<<' '<<_z<<'\n';
}
template<class T1, class T2, class T3, class T4>
inline void debug(T1 _x,T2 _y,T3 _z,T4 _zz) {
    cout<<_x<<' '<<_y<<' '<<_z<<' '<<_zz<<'\n';
}
template< class T1>
inline void debug(T1 _array,int _size) {
    cout<<"[";
    for (int i=0; i<_size; ++i) {
        cout<<' '<<_array[i];
    }
    puts(" ]");
}

#define getchar getchar_unlocked
#define putchar putchar_unlocked

inline void fastRead(int *a) {
    register char c=0;
    while (c<33) c=getchar();
    *a=0;
    while (c>33)
    {
        *a=*a*10+c-'0';
        c=getchar();
    }
}
inline string fastRead() {
    register char c[33];
    gets(c);
    return (string)c;
}
inline bool CI(int &_x) {
    return scanf("%d",&_x)==1;
}
inline bool CI(int &_x, int &_y) {
    return CI(_x)&&CI(_y) ;
}
inline bool CI(int &_x, int &_y, int &_z) {
    return CI(_x)&&CI(_y)&&CI(_z) ;
}
inline bool CI(int &_x, int &_y, int &_z, int &_zz) {
    return CI(_x)&&CI(_y)&&CI(_z)&&CI(_zz) ;
}
inline void wait( double seconds ) {
    double endtime = clock()+( seconds* CLOCKS_PER_SEC );
    while ( clock() < endtime ) {
        ;
    }
}

double Distance;
double galon_capacity;
double miles_per_gallon;
double cost_filling_origin;
int routeCount;
struct Route {
    double Distance_from_origin;
    double cost_per_gallon;
    Route( double Distance_from_origin=0.0, double cost_per_gallon=0.0):
            Distance_from_origin(Distance_from_origin),cost_per_gallon(cost_filling_origin) {
        ;
    }
};
inline bool cmp( Route A, Route B) {
    return A.Distance_from_origin < B.Distance_from_origin;
}
Route stations[55];

inline void read() {
    scanf("%lf %lf %lf",&galon_capacity,&miles_per_gallon,&cost_filling_origin);
    scanf("%d",&routeCount);
    fo(i,routeCount) {
        scanf("%lf %lf",&stations[i].Distance_from_origin,&stations[i].cost_per_gallon);
        stations[i].cost_per_gallon/=100.0;
    }
}
const double eps = 1e-9;
const double inf=1023456789;

double go(int at,double fuel, double dist) {

    if ( (fuel*miles_per_gallon)+dist>=Distance )return 0;
    if (at>=routeCount)return inf;


    double bst=inf;
    double distance_travel = abs(dist-stations[at].Distance_from_origin);
    double fuel_baki_thakbe = fuel-(distance_travel/miles_per_gallon);

    bst=min(bst, go(at+1, fuel , dist) );
    if ( (fuel_baki_thakbe*2.0) > galon_capacity ) {
        bst=min(bst, go(at+1, fuel_baki_thakbe , stations[at].Distance_from_origin) );
    }
    if ( fuel_baki_thakbe>=0.0 ) {
        double fuel_vorbo = galon_capacity-fuel_baki_thakbe;
        double fuel_babod_cost = stations[at].cost_per_gallon*fuel_vorbo;
        bst=min(bst, fuel_babod_cost+2.0+go(at+1, galon_capacity,stations[at].Distance_from_origin) );
    }

    return bst;
}

inline void Solve() {
    read();
    sort(stations,stations+routeCount, cmp);
    double res=go(0,galon_capacity,0)+cost_filling_origin;
    cout<<res<<'\n';

}

//#define showcase
int main() {
    cout<<setprecision(2)<<fixed;
    int kase=1;
    while ( scanf("%lf",&Distance)==1 ) {
        if (Distance<=-1)break;
        cout<<"Data Set #"<<kase++<<"\n";
        cout<<"minimum cost = $";
        Solve();
    }

    return 0;
}
// kate: indent-mode cstyle; space-indent on; indent-width 0; 





